package com.wwy;

import org.jb2011.lnf.beautyeye.BeautyEyeLNFHelper;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.context.ApplicationContext;

import javax.swing.*;

/**
 * @Author: wwy
 * @Date: 2020/8/13 12:24
 */
@SpringBootApplication
public class XYApplication {
    public static void main(String[] args) {
        try {
            org.jb2011.lnf.beautyeye.BeautyEyeLNFHelper.launchBeautyEyeLNF();
            BeautyEyeLNFHelper.frameBorderStyle = BeautyEyeLNFHelper.FrameBorderStyle.translucencyAppleLike;
            UIManager.put("RootPane.setupButtonVisible", false);
        } catch(Exception e) {
            //TODO exception
        }
        ApplicationContext applicationContext = new SpringApplicationBuilder(XYApplication.class)
                .headless(false).run(args);
        SwingArea.applicationContext = applicationContext;
        LabelDialog.applicationContext = applicationContext;
        TypeDialog.applicationContext = applicationContext;
        RssiDialog.applicationContext = applicationContext;
        FiltrationTimeDialog.applicationContext = applicationContext;
    }

    public XYApplication() {
        SwingArea.getInstance().initUI();
    }
}
